{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "import plotly as py\n",
    "import plotly.graph_objs as go\n",
    "import plotly.figure_factory as FF\n",
    "\n",
    "import numpy as np\n",
    "import pandas as pd\n",
    "\n",
    "import warnings\n",
    "warnings.filterwarnings(\"ignore\", message=\"numpy.dtype size changed\")\n",
    "warnings.filterwarnings(\"ignore\", message=\"numpy.ufunc size changed\")\n",
    "\n",
    "py.offline.init_notebook_mode(connected=True)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "X = np.random.weibull(1.25, size=1000)\n",
    "X[:10]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "trace1 = go.Histogram(\n",
    "    x=X,\n",
    "    xbins=dict(\n",
    "        start=np.min(X),\n",
    "        size=0.25,\n",
    "        end=np.max(X),\n",
    "    ),\n",
    "    marker=dict(\n",
    "        color='#00EEEE',\n",
    "    )\n",
    ")\n",
    "\n",
    "layout = go.Layout(\n",
    "    title='Test Histogram',\n",
    ")\n",
    "\n",
    "print(type(trace1), type(go.Data([trace1])))\n",
    "\n",
    "fig = go.Figure(data=go.Data([trace1]), layout=layout)\n",
    "py.offline.iplot(figure_or_data=fig, filename='Histogram-Test')"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.4.3"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
